import Cookies from 'js-cookie'

const projectName = window.SITE_CONFIG['projectName']

function makeKey (key) {
  return projectName + '.' + key
}

export default {
  set (key, value, opts) {
    // console.log(makeKey(key))
    Cookies.set(makeKey(key), value, opts)
  },
  get (key) {
    return Cookies.get(makeKey(key))
  },
  remove (key) {
    Cookies.remove(makeKey(key))
  }
}
